home *** CD-ROM | disk | FTP | other *** search
/ PC World Komputer 1997 November / Pcwk1197.iso / LOTUS / Eng-ins / ACROREAD / SUITE / DW08_S6.APR / SCRIPT / ApproachDoc / Invoice - Main / Body / Invoice Number.s (.txt) < prev    next >
Null Bytes Alternating  |  1996-10-27  |  2KB  |  24 lines

  1. '++LotusScript Development Environment:2:5:(Options):0:66
  2.  
  3. '++LotusScript Development Environment:2:5:(Forward):0:1
  4. Declare Sub Gotfocus(Source As Fieldbox)
  5.  
  6. '++LotusScript Development Environment:2:5:(Declarations):0:2
  7.  
  8. '++LotusScript Development Environment:2:2:BindEvents:1:129
  9. Private Sub BindEvents(Byval Objectname_ As String)
  10.     Static Source As FIELDBOX
  11.     Set Source = Bind(Objectname_)
  12.     On Event Gotfocus From Source Call Gotfocus
  13. End Sub
  14.  
  15. '++LotusScript Development Environment:2:2:Gotfocus:1:12
  16. Sub Gotfocus(Source As Fieldbox)
  17.     Dim rev As Currency, expense As Currency, bal As Currency
  18.     rev@ = Ccur(Inputbox("How much did we make this month?"))
  19.     expense@ = Ccur(Inputbox("How much did we spend?"))
  20.     bal@ = rev@ - expense@
  21.     Messagebox "Our balance this month is "_
  22.     & Format(bal@, "Currency")
  23.     Source.text=Cstr(bal@)
  24. End Sub